//
//  SHSessionConfig.m
//  Netease
//
//  Created by 王方伟 on 2017/12/22.
//  Copyright © 2017年 wfw. All rights reserved.
//

#import "SHSessionConfig.h"
#import "UIImage+NIMKit.h"

@implementation SHSessionConfig


#pragma mark 更多菜单配置
- (NSArray<NIMMediaItem *> *)mediaItems{
    return @[[NIMMediaItem item:@"onTapMediaItemPicture:"
                    normalImage:[UIImage nim_imageInKit:@"bk_media_picture_normal"]
                  selectedImage:[UIImage nim_imageInKit:@"bk_media_picture_nomal_pressed"]
                          title:@"相册"],
             
             [NIMMediaItem item:@"onTapMediaItemShoot:"
                    normalImage:[UIImage nim_imageInKit:@"bk_media_shoot_normal"]
                  selectedImage:[UIImage nim_imageInKit:@"bk_media_shoot_pressed"]
                          title:@"拍摄"],
             
             [NIMMediaItem item:@"onTapMediaItemLocation:"
                    normalImage:[UIImage nim_imageInKit:@"bk_media_position_normal"]
                  selectedImage:[UIImage nim_imageInKit:@"bk_media_position_pressed"]
                          title:@"位置"],
             ];
}

#pragma mark 输入相关配置
- (NSArray<NSNumber *> *)inputBarItemTypes{
    if (self.session.sessionType == NIMSessionTypeP2P && [[NIMSDK sharedSDK].robotManager isValidRobot:self.session.sessionId]){
        //和机器人 点对点 聊天
        return @[
                 @(NIMInputBarItemTypeTextAndRecord),
                 ];
    }
    return @[
             @(NIMInputBarItemTypeVoice),
             @(NIMInputBarItemTypeTextAndRecord),
             @(NIMInputBarItemTypeEmoticon),
             @(NIMInputBarItemTypeMore)
             ];
}
@end
